.TH std::pointer_safety 3 "2024.06.10" "http://cppreference.com" "C++ Standard Libary"
.SH NAME
std::pointer_safety \- std::pointer_safety

.SH Synopsis
   Defined in header <memory>
   enum class pointer_safety {

        relaxed,                \fI(since C++11)\fP
        preferred,              (removed in C++23)
        strict

   };

   The scoped enumeration type pointer_safety lists the pointer safety modes supported
   by C++.

   Enumeration constants

                             Only safely-derived pointers (pointers to objects
   pointer_safety::strict    allocated with new or subobjects thereof) may be
                             dereferenced or deallocated. Garbage collector may be
                             active.
                             All pointers are considered valid and may be dereferenced
   pointer_safety::preferred or deallocated. A reachability-based leak detector may be
                             active.
   pointer_safety::relaxed   All pointers are considered valid and may be dereferenced
                             or deallocated.

.SH See also

   get_pointer_safety returns the current pointer safety model
   \fI(C++11)\fP            \fI(function)\fP
   (removed in C++23)
